package testy;

import static org.junit.Assert.*;
import gra.Table;

import org.junit.Test;

import GUI.Controler;

public class TableTest
{
    @Test
    public void testTable()
    {
        Table stol = new Table(2,0);
        assertNotNull(stol);
        try 
        {
            stol.gameloop();
        } 
        catch (Throwable e) 
        {
            System.out.println("Blad");
        }
        
    }
    @Test(expected = IllegalArgumentException.class) 
    public void testTable2()
    {
        Table stol = new Table(200,1840);
        assertNotNull(stol);
        try 
        {
            stol.gameloop();
        }
        catch(IllegalArgumentException e2)
        {
            System.out.println("Blad inicjalizacji stolu do gry.");
        }
        catch (Throwable e) 
        {
            System.out.println("Blad.");
        }
        
    }
}
